package com.rapid.maintenance.ui.activity.paimai;

import android.view.LayoutInflater;

import com.rapid.maintenance.R;
import com.rapid.maintenance.adapter.ErshouResultAdapter;
import com.rapid.maintenance.adapter.QingcangAdapter;
import com.rapid.maintenance.base.BaseActivity;

import java.util.ArrayList;
import java.util.List;

import androidx.recyclerview.widget.LinearLayoutManager;
import androidx.recyclerview.widget.RecyclerView;
import butterknife.BindView;

public class ZhenghuoqingcangMallActivity extends BaseActivity {
    @BindView(R.id.rv_ershou)
    RecyclerView rv_ershou;
    QingcangAdapter ershouResultAdapter;

    @Override
    protected int provideRootLayout() {
        return R.layout.activity_paimai_zhenghuoqingcang;
    }

    @Override
    protected void init() {
        setTitle("正货清仓");
        rv_ershou.setLayoutManager(new LinearLayoutManager(this));
        rv_ershou.setAdapter(ershouResultAdapter = new QingcangAdapter());
        initDate();
    }

    private void initDate() {
        List<Object> objects = new ArrayList<>();
        objects.add(new Object());
        objects.add(new Object());
        objects.add(new Object());
        objects.add(new Object());
        objects.add(new Object());
        ershouResultAdapter.setNewData(objects);
        ershouResultAdapter.addHeaderView(LayoutInflater.from(this).inflate(R.layout.layout_header_qingcang_mall,null));
    }
}
